<%@page import="java.util.ArrayList"%>
<%@page import="java.io.PrintWriter"%>
<%@page import="org.apache.catalina.connector.Request"%>
<%@page import="classes.DBManager"%>
<%@page import="classes.User"%>
<%@page import="classes.SubjectManager"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Lecturer Page</title>
</head>
<body>
	<h1>Subjects:</h1>
	<%
		HttpSession ses = request.getSession();
		User user = (User) ses.getAttribute("user");
		int lecturer_id = user.getUserId();
		ArrayList<Integer> arr = user.getSubjectsLector();
		for (int i = 0; i < arr.size(); i++) {
			String subject_name = SubjectManager.getSubjectName(arr.get(i));
			out.println("<b><ul><li><a href=\"groupsForLectures.jsp?subject="
					+ subject_name
					+ "&subject_id="
					+ arr.get(i)
					+ "&id="
					+ lecturer_id
					+ "\">"
					+ subject_name
					+ "</a></li></ul></b>");
		}
	%>
	<a href="AccountSettings.jsp">Account Settings</a>
</body>
</html>